package com.lwlean.test.redis;

import org.apache.commons.pool2.impl.GenericObjectPoolConfig;
import redis.clients.jedis.Jedis;
import redis.clients.jedis.JedisPool;

/**
 * Created by lean on 16-12-4.
 */
public class RedisStandaloneUtil {

    private static JedisPool jedisPool;

    static {
        jedisPool = new JedisPool(new GenericObjectPoolConfig(),"127.0.0.1",6380);
    }

    public static Jedis getJedis(){
        return jedisPool.getResource();
    }


}
